﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using HandyControl.Controls;
using YJTMedicalAideManage.Cores.Events;
using YJTMedicalAideManage.Cores.Globals;

namespace YJTMedicalAideManage.MAM.Views
{
    /// <summary>
    /// MAMView.xaml 的交互逻辑
    /// </summary>
    public partial class MAMView : UserControl
    {
        public MAMView()
        {
            InitializeComponent();
        }
        
        private void Pagination_PageUpdated(object sender, HandyControl.Data.FunctionEventArgs<int> e)
        {
            PaginationEvent.Instance.PushMessage();
        }

        private void ToggleButton_Click(object sender, RoutedEventArgs e)
        {
            StatusEvent.Instance.PushMessage(GlobalApp.Instance.OperatorId);
        }

        private void BeginDate_SelectedDateChanged(object sender, SelectionChangedEventArgs e)
        {
            BeginDate.DisplayDate = DateTime.Now;
        }

        private void EndDate_SelectedDateChanged(object sender, SelectionChangedEventArgs e)
        {
            EndDate.DisplayDate = DateTime.Now;
        }
    }
}
